// Created by zyq on 2025/3/26.
#include "iostream"

using namespace std;

class Person {
public:
    string name;

    Person(string name) {
        this->name = name;
    }

    void show() {
        cout << "name:" << name << endl;
    }
};

class Finery {
public:
    virtual void show() const = 0;

    virtual ~Finery() {}
};

class TShirts : public Finery {
public:
    void show() const override {
        cout << "大T恤" << endl;
    }
};

class BigTrouser : public Finery {
public:
    void show() const override {
        cout << "垮裤" << endl;
    }
};

class Suit : public Finery {
public:
    void show() const override {
        cout << "西装" << endl;
    }
};

class Tie : public Finery {
public:
    void show() const override {
        cout << "领带" << endl;
    }
};

int main() {

//    cout << "第一次装扮" << endl;
//    Person *p = new Person("aaa");
//    p->show();
//    Finery *t = new TShirts();
//    t->show();
//    Finery *b = new BigTrouser();
//    b->show();

    cout << "第二次装扮" << endl;
    Person *p = new Person("bbb");
    p->show();
    Finery *s = new Suit();
    s->show();
    Finery *t = new Tie();
    t->show();

    return 0;
}

